import common from './env/common'

const env = process.env.NODE_ENV || 'development'


// const config = require(`./env/${env}`).default

// win下 似乎require无法使用变量
// const config = require(`./env/${env}`).default
let config = {}

console.log(`当前环境是${env}`)
switch (env) {
  case 'test':
    config = require('./env/test').default
    break;
  case 'production':
    config = require('./env/production').default
    break;
  default:
    config = require('./env/development').default
}

export default Object.assign({}, common, config)
